package pl.elka.simulator.core.experiment;

import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;

import pl.elka.simulator.core.Position;

public class ConsistencyGraphNode {
	private final int id;	
	
	public ConsistencyGraphNode(Position position, int id){
		this.id = id;
		this.position = position;
	}
	
	public Set<ConsistencyGraphNode> neighbours = new HashSet<ConsistencyGraphNode>();
	public final Position position;
	public boolean addedToTree = false;

	@Override
	public int hashCode() {	
		return id;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		ConsistencyGraphNode other = (ConsistencyGraphNode) obj;
		if (id != other.id)
			return false;
		return true;
	}
	
}
